package br.com.naybee.framework.client.notification;


public class NotificationSimple{

	public static native void showSuccessToast(String msg) /*-{
		$wnd.$().toastmessage('showSuccessToast',msg);
	}-*/;
	
	public static native void showStickySuccessToast(String msg) /*-{
		$wnd.$().toastmessage('showToast', {
				text : msg,
				sticky : true,
				position : 'top-right',
				type : 'success',
				closeText : '',
				close : function() {console.log("toast is closed ...");
			}
		});
	}-*/;
	
	public static native void showNoticeToast(String msg) /*-{
		$wnd.$().toastmessage('showNoticeToast', msg);
	}-*/;
	
	public static native void showStickyNoticeToast(String msg) /*-{
		$wnd.$().toastmessage('showToast', {
			text : msg,
			sticky : true,
			position : 'top-right',
			type : 'notice',
			closeText : '',
			close : function() {
				console.log("toast is closed ...");
			}
		});
	}-*/;
	
	public static native void showWarningToast(String msg) /*-{
		$wnd.$().toastmessage('showWarningToast', msg);
	}-*/;

	public static native void showStickyWarningToast(String msg) /*-{
		$wnd.$().toastmessage('showToast', {
			text : msg,
			sticky : true,
			position : 'top-right',
			type : 'warning',
			closeText : '',
			close : function() {
				console.log("toast is closed ...");
			}
		});
	}-*/;
	
	public static native void showErrorToast(String msg) /*-{
		$wnd.$().toastmessage('showErrorToast', msg);
	}-*/;
	
	public static native void showStickyErrorToast(String msg) /*-{
		$wnd.$().toastmessage('showToast', {
			text : msg,
			sticky : true,
			position : 'top-right',
			type : 'error',
			closeText : '',
			close : function() {
				console.log("toast is closed ...");
			}
		});
	}-*/;


}
